package com.example.task;

import lombok.extern.slf4j.Slf4j;
import org.activiti.engine.delegate.DelegateExecution;
import org.activiti.engine.delegate.JavaDelegate;
import org.springframework.stereotype.Component;

/**
 * @Deacription TODO
 * @Author baohuajie
 * @Date 2021/1/16 17:32
 * @Version 1.0
 **/
@Slf4j
@Component
public class Task22 implements JavaDelegate {
    @Override
    public void execute(DelegateExecution execution) {
        log.info("Task22 start,thread:{}", Thread.currentThread().getName());
        log.info("Task22 instanceId:{}", execution.getProcessInstanceId());
        log.info("Task22 executionId:{}", execution.getId());
        try {
            Thread.sleep(2000);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        log.info("Task22 end");
    }
}
